/**
 * 
 */
package niuke;

import java.util.Scanner;

/**
 * @author zhongfang
 *
 */
public class 膨胀的牛牛 {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		Scanner scanner=new Scanner(System.in);
		int n=scanner.nextInt();
		int A=scanner.nextInt();
		for (int i = 0; i < n; i++) {
			if(A==scanner.nextInt()){
				A<<=1;
			}
		}
		System.out.println(A);
	}
}
